package com.wgzx.modbus.factory;

import com.wgzx.modbus.codec.ModbusDecoder;
import com.wgzx.modbus.codec.ModbusEncoder;
import io.netty.handler.codec.ByteToMessageDecoder;
import io.netty.handler.codec.MessageToByteEncoder;

public class ModbusCodecFactory implements CodecFactory {

    public static final ModbusCodecFactory INSTANCE = new ModbusCodecFactory();

    @Override
    public ByteToMessageDecoder getModbusDecoder() {
        return new ModbusDecoder();
    }

    @Override
    public MessageToByteEncoder getModbusEncoder() {
        return new ModbusEncoder()  ;
    }
}
